<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags" %>
<s:bean name="model.bean.CollectionPropertiesBean" var="bean"/>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>添加下载资源</title>
	<script src="<%=basePath%>ckeditor/ckeditor.js" type="text/javascript"></script>
	<script src="<%=basePath%>ckfinder/ckfinder.js" type="text/javascript"></script>
	<script src="<%=basePath%>WebsiteBackstage/js/jquery-1.7.2.js" type="text/javascript"></script>  
	<script src="<%=basePath%>ckeditor/adapters/jquery.js" type="text/javascript"></script>
	
	<link href="<%=basePath%>WebsiteBackstage/css/validationEngine.jquery.css" rel="stylesheet" type="text/css" />
	<link href="<%=basePath%>WebsiteBackstage/css/template.css" rel="stylesheet" type="text/css" />
	<script src="<%=basePath%>WebsiteBackstage/js/jquery.validationEngine-zh_CN.js" type="text/javascript"></script> 
	<script src="<%=basePath%>WebsiteBackstage/js/jquery.validationEngine.js" type="text/javascript"></script>
	<script>
		$(document).ready(function () {
			$("#form1").validationEngine();
        });
    </script>
    
    <script type="text/javascript" src="<%=basePath%>WebsiteBackstage/js/jquery-calendar.js"></script>
	<link rel="stylesheet" type="text/css" href="<%=basePath%>WebsiteBackstage/css/jquery-calendar.css">
	<script type="text/javascript">
		$(document).ready(function (){
			$("#time1").calendar();
		});
	</script>
</head>
<body>
	添加内容：
	<s:form action="download_add" id="form1" method="post" enctype="multipart/form-data">
    		<s:textfield name="downloadFile.file_name" label="自命名文件名"  Class="validate[required,maxSize[50]] text-input"/>
    		<s:file name="pic" label="文件上传"/>
    		<s:textfield name="downloadFile.file_path" label="上传文件名" Readonly="true"/>
    		<s:textfield name="downloadFile.file_size" label="软件大小" Readonly="true"/>
    		<s:textfield name="downloadFile.download_times" label="下载次数" value="0" Readonly="true"/>
    		<s:textfield name="downloadFile.developers" label="开发商" />

    		<s:radio name="downloadFile.properties" list="#bean.list" listKey="key" listValue="value" value="0" label="软件性质" />
    		
    		<s:textfield name="downloadFile.date_retired" id="time1" label="添加时间" Class="calendarFocus" Readonly="true"/>
    		
    		<s:radio list="#{'0':'正常','1':'结束'}" name="downloadFile.state" value="0" label="状态"/>
    		
     		<s:textarea name="downloadFile.explain" rows="30" cols="50" label="文件说明"/>
     		<script type="text/javascript">  
                 $('#editor').ckeditor();  
                 var editor = CKEDITOR.replace('downloadFile.explain');
                 CKFinder.setupCKEditor(editor, '/sshWeb/ckfinder/');
            </script>
    		<s:submit/>
		</s:form>
		
</body>
</html>